package com.flower8.service;

import com.flower8.model.Recommend;
import com.flower8.utils.PageData;

import java.util.List;

/**
 * @Description:
 * @Author: tanglin
 * @Date: 2019/10/23 11:25
 * @Version: 1.0
 */
public interface RecommendService {
    /**
     * 查询推荐列表
     * @param pd
     * @return
     * @throws Exception
     */
    List<Recommend> getRecommendList(PageData pd) throws Exception;

    /**
     * 查询推荐列表数量
     * @param pd
     * @return
     * @throws Exception
     */
    int getRecommendListCount(PageData pd) throws Exception;

    /**
     * 根据推荐卡id查询
     * @param pd
     * @return
     */
    Recommend getRecommendById(PageData pd)throws Exception;

    /**
     * 更新推荐
     * @param recommend
     * @throws Exception
     */
    void updateRecommend(Recommend recommend)throws  Exception;

    /**
     * 删除推荐
     * @param id
     * @throws Exception
     */
    void deleteRecommend(long id) throws  Exception;

    /**
     * 新增推荐
     * @param recommend
     * @throws Exception
     */
    void addRecommend(Recommend recommend)throws  Exception;
}
